GUI Help > Create > createRadioButton

createRadioButton
int handle=createRadioButton(int x, int y, int width, int height, str caption, handle parent)

Description:
Creates a radiobutton. Radiobuttons are similar to checkboxes except that instead of only having on/off options to choose from, the user selects one radiobutton from a group of radiobuttons. Only one radiobutton from a group can be selected at once. Radiobuttons belong to the same group if they have the same parent gadget.

Return Value:
Handle to the new gadget.

Parameters:
x X position of new gadget
y Y position of new gadget
width Width of new gadget in pixels
height Height of new gadget in pixels
caption The text which appears next to the radiobutton.
parent Handle to the parent of the new gadget, or 0 for the main window
Remarks:
You must not use a frame gadget as the parent for a radiobutton, this may cause drawing errors under Windows XP. Instead, either create the radiobutton as a sibling of the frame (ie. the frame and radiobutton have the same parent), or create a panel inside the frame, and place the radiobutton inside the panel.

See Also:


Example:
(Note: You will need to include the GUI constants file for this example to work)